import java.util. * ;
public class whileDemo {
    public static void main(String[] args) {
        int n= 0,i= 1,s= 0;
        Scanner reader = new Scanner( System.in) ;
        while((n = reader.nextInt()) > 80 && n < 30){
            System.out.println("请重新输入");
            n = reader.nextInt();
        }
        while(i <= n){
            s += i;
            i++;
        }
        System. out. println( "1+2+3+...+" + n + "= " + s) ;
    }
}
